package com.bys.ots.controller.job;

import com.bys.ots.config.wx.WxTokenUpdate;
import com.bys.ots.config.wx.job.JobWxTokenUpdate;
import com.bys.ots.service.ComplaintService;
import com.bys.ots.service.impl.ComplaintServiceImpl;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.ApplicationArguments;
import org.springframework.boot.ApplicationRunner;
import org.springframework.context.annotation.Configuration;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;

@Component
@Configuration
//@EnableScheduling

public class TestUpdate
{
    private final Logger logger = LoggerFactory.getLogger(JobWxTokenUpdate.class);
    @Resource
    ComplaintService complaintService;

    //@Scheduled(cron = "0 30 2 * * ?")
    private void update() {
        complaintService.checkProduce();
    }

}
